<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      //   var time = Date();
      //   console.log(time);
      var time = new Date();
      var year = time.getFullYear();
      console.log(year);
      var month = time.getMonth();
      console.log(month);
      var date = time.getDate();
      console.log(date);
      var day = time.getDay();
      console.log(day);
      var hour = time.getHours();
      console.log(hour);
      var minute = time.getMinutes();
      console.log(minute);
      var second = time.getSeconds();
      console.log(second);
    </script>
  </body>
</html>
